home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-02 / wgt_tp1.zip / COMMANDS.DOC < prev    next >
Text File  |  1992-07-05  |  32KB  |  907 lines

  1.                         WordUp Graphics Toolkit
  2.                             Command Summary
  3.  
  4. _Bar procedure
  5. ------------------------------------------------------------------------------
  6. Function  1    Draws a filled rectangle with current color on active graphics
  7.                page.
  8.  
  9. Declaration    _Bar(x1,y1,x2,y2 : INTEGER)
  10.  
  11. Remarks        See _Rectangle.
  12.  
  13.  
  14.  
  15.  
  16. Block_Height function
  17. ------------------------------------------------------------------------------
  18. Function       Returns height of a previously stored block.
  19.  
  20. Declaration    Block_Height(blockname : POINTER)
  21.  
  22. Result Type    Integer
  23.  
  24.  
  25.  
  26.  
  27. Block_Width function
  28. ------------------------------------------------------------------------------
  29. Function       Returns width of a previously stored block.
  30.  
  31. Declaration    Block_Width(blockname : POINTER)
  32.  
  33. Result Type    Integer
  34.  
  35.  
  36.  
  37.  
  38. _Circle procedure
  39. ------------------------------------------------------------------------------
  40. Function       Draws a circle using (x,y) as the center point.
  41.                Operates on current color and graphics page.
  42.  
  43. Declaration    _Circle(x,y,radius : INTEGER)
  44.  
  45. Remarks        The circle is drawn using the current color set by _SetColor.
  46.                Aspect ratios are not used, therefore results may be slightly
  47.                different than the BGI counterpart.
  48.  
  49. See also       _SetColor, Filled_Circle
  50.  
  51.  
  52.  
  53.  
  54. _ClearDevice procedure
  55. ------------------------------------------------------------------------------
  56. Function       Clears the currently selected graphics page with a specified
  57.                color number.
  58.  
  59. Declaration    _ClearDevice(color : BYTE)
  60.  
  61. Remarks        This command behaves like the BGI ClearDevice procedure except
  62.                that it allows you to use a certain "clearing" color and it
  63.                supports WGT's multiple graphics pages.
  64.  
  65. Restrictions   Does not handle clipping.
  66.  
  67. See also       Currentscreen variable, _ClearViewPort procedure
  68.  
  69.  
  70.  
  71.  
  72. _ClearViewPort procedure
  73. ------------------------------------------------------------------------------
  74. Function       Clear the currently selected graphics page with a specified
  75.                color number (only within clipping boundaries).
  76.  
  77. Declaration    _ClearViewPort(color : BYTE)
  78.  
  79. Remarks        Same as _ClearDevice except it operates with clipping ranges.
  80.  
  81. See also       _ClearDevice, _SetViewPort
  82.  
  83.  
  84.  
  85.  
  86. Color_Rotate procedure
  87. ------------------------------------------------------------------------------
  88. Function       Cycles the colors within a specified group from a palette
  89.                variable.
  90.  
  91. Declaration    Color_Rotate(start,finish : WORD; dir : DIRECTIONS;
  92.                             VAR pal : PALETTE)
  93.  
  94. Remarks        This routine takes the colors from Start to Finish and shifts
  95.                them one in the direction specified by DIR. This effect can
  96.                be used to similate animation. DIRECTIONS is a variable type
  97.                available only for WGT and cannot be used in standard TP. It
  98.                is defined as follows:
  99.  
  100.                TYPE Directions = (up, down, left, right)
  101.                Up and Left are treated as the same thing, as are Down and
  102.                Left (all four are used for scrolling screen sections).
  103.  
  104. See also       _SetRGBPalette, Fade_In, Fade_Out
  105.  
  106.  
  107.  
  108.  
  109. Copy_Screen procedure
  110. ------------------------------------------------------------------------------
  111. Function       Copies a section of one screen onto a different WGT page.
  112.  
  113. Declaration    Copy_Screen(x1,y1,x2,y2 : INTEGER; source : SCREENPTR;
  114.                            dx,dy : INTEGER; dest : POINTER)
  115.  
  116. Remarks        This command can seem confusing, but is very powerful, and
  117.                necessary when using multiple graphics pages. A second page
  118.                must be initialized with Init_Screen before this command can
  119.                be used. 
  120.                
  121.                The area defined by (x1,y1,x2,y2) is copied from the screen
  122.                described by SOURCE, and is placed with the upper left corner
  123.                at (dx,dy) on the screen referred to by DEST. For example,
  124.                to copy screen SECOND(entirely) to the visual screen, type
  125.                Copy_Screen(0,0,319,199,SECOND,0,0,BASESCREEN). Basescreen is
  126.                a constant which is used to describe the visual screen.
  127.  
  128. See also       Init_Screen, Patches, Remove_Screen
  129.  
  130.  
  131.  
  132.  
  133. Fade_In procedure
  134. ------------------------------------------------------------------------------
  135. Function       Gradually fades in a group of colors from a palette variable
  136.                (using a specified speed).
  137.  
  138. Declaration    Fade_In(start,finish : WORD; pal : PALETTE; speed : BYTE)
  139.  
  140. Remarks        The colors from Start to Finish are faded in starting from
  141.                black. The speed may range from (0..255), and is similar to
  142.                using the DELAY command between each change of the colors.
  143.  
  144. See also       Fade_Out, _SetRGBPalette, Set_Palette_Block
  145.  
  146.  
  147.  
  148.  
  149. Fade_Out procedure
  150. ------------------------------------------------------------------------------
  151. Function       Gradually fades out a group of colors from a palette variable
  152.                (using a specified speed).
  153.  
  154. Declaration    Fade_Out(start,finish : WORD; pal : PALETTE; speed : BYTE)
  155.  
  156. Remarks        Same as Fade_In except colors result in black.
  157.  
  158. See also       Fade_In, _SetRGBPalette, Set_Palette_Block
  159.  
  160.  
  161.  
  162.  
  163. Filled_Circle procedure
  164. ------------------------------------------------------------------------------
  165. Function       Draws a filled circle using (x,y) as the center point.
  166.  
  167. Declaration    Filled_Circle(x,y,radius : INTEGER)
  168.  
  169. Remarks        See _Circle
  170.  
  171.  
  172.  
  173.  
  174. Flip_Block procedure
  175. ------------------------------------------------------------------------------
  176. Function       Flips a block in one of two directions (block is physically
  177.                changed in memory, not on screen).
  178.  
  179. Declaration    Flip_Block(VAR blockname : POINTER; flipdir : FLIP)
  180.  
  181. Remarks        This procedure will flip a previously stored image either
  182.                vertically or horizontally. The stored image is physically
  183.                changed, and therefore the results will not be seen until
  184.                the block is displayed.
  185.  
  186.                FLIP is a variable type which is exclusive to WGT and may
  187.                not be used otherwise. It is defined as follows:
  188.  
  189.                TYPE flip = (Horizontal, Vertical)
  190.  
  191. See also       Put_Block, New_Block, Resize_Block, Free_Block
  192.  
  193.  
  194.  
  195.  
  196. Free_Block procedure
  197. ------------------------------------------------------------------------------
  198. Function       Releases memory used to store an image.
  199.  
  200. Declaration    Free_Block(VAR blockname : POINTER)
  201.  
  202. Remarks        Used when a program is finished with a stored image. This is
  203.                similar to the BGI FREEMEM.
  204.  
  205. See also       New_Block
  206.  
  207.  
  208.  
  209.  
  210. FreeSprites procedure
  211. ------------------------------------------------------------------------------
  212. Function       De-allocates the memory used by LOADSPRITES.
  213.  
  214. Declaration    FreeSprites(VAR block : SPRITES)
  215.  
  216. Remarks        Removes sprites from memory.
  217.  
  218. See Also       LoadSprites
  219.  
  220.  
  221.  
  222.  
  223. _GetPixel function
  224. ------------------------------------------------------------------------------
  225. Function       Gets the pixel value at X,Y. Uses current graphics page.
  226.  
  227. Declaration    _GetPixel(x,y : INTEGER);
  228.  
  229. Result Type    Word
  230.  
  231. See also       _PutPixel
  232.  
  233.  
  234.  
  235.  
  236. Get_Transluscent function
  237. ------------------------------------------------------------------------------
  238. Function       Returns current transluscent color used by PutBlock.
  239.  
  240. Declaration    Get_Transluscent
  241.  
  242. Result Type    Byte
  243.  
  244. Remarks        See Set_Transluscent.
  245.  
  246. See also       Put_Block, Set_Transluscent
  247.  
  248.  
  249.  
  250.  
  251. Init_Screen procedure
  252. ------------------------------------------------------------------------------
  253. Function       Initializes a 64K block of memory to act as a graphics page.
  254.  
  255. Declaration    Init_Screen(VAR screenname : SCREENPTR);
  256.  
  257. Remarks        This is the closest available to page flipping techniques for
  258.                this graphics mode. All graphics operations in WGT work on the
  259.                pages created by this procedure. A variable must be set by
  260.                your program to tell WGT which screen to use. To do so,
  261.                type CURRENTSCREEN:= and then the name of the pointer to the
  262.                other screen. BGI functions do not work on these screens.
  263.  
  264. See also       Copy_Screen, Patches, Remove_Screen
  265.  
  266.  
  267.  
  268.  
  269. _Line Procedure
  270. ------------------------------------------------------------------------------
  271. Function       Draws a line on the current graphics page from (x1,y1) to 
  272.                (x2,y2). Operates on current color and graphics page.
  273.  
  274. Declaration    _Line(x1,y1,x2,y2 : INTEGER)
  275.  
  276. Remarks        Replaces all needs for BGI's line command except where a 
  277.                line style other than SolidLn is required. Horizontal lines
  278.                are significantly faster than BGI's.
  279.  
  280. Restrictions   Does not allow for different line styles or thicknesses.
  281.  
  282. See also       _Setcolor
  283.  
  284.  
  285.  
  286.  
  287. Load_Block procedure
  288. ------------------------------------------------------------------------------
  289. Function       Loads a previously saved image from disk into a pointer.
  290.  
  291. Declaration    Load_Block(filename : STRING; VAR blockname : POINTER)
  292.  
  293. Remarks        The pointer must be set to NIL before this routine is called.
  294.                Load_Block automatically initializes the appropriate amount
  295.                of memory and loads the data. There is no need for a call
  296.                to New_Block (in fact, don't do it or this won't work).
  297.  
  298. See also       Save_Block
  299.  
  300.  
  301.  
  302.  
  303. LoadPAK procedure
  304. ------------------------------------------------------------------------------
  305. Function       Loads a previously stored image from disk in compressed
  306.                format.
  307.  
  308. Declaration    LoadPAK(filename : STRING; VAR blockname : POINTER)
  309.  
  310. Remarks        This is similar to Load_Block except that the image is
  311.                in a file which was created by SavePAK. The compression used
  312.                is "similar" to PCX format (sometimes better). The more
  313.                simplistic the image, the smaller the file.
  314.  
  315. See also       SavePAK, Load_Block
  316.  
  317.  
  318.  
  319.  
  320. Load_Palette procedure
  321. ------------------------------------------------------------------------------
  322. Function       Load a 768 byte palette file from disk into a palette
  323.                variable.
  324.  
  325. Declaration    Load_Palette(filename : STRING; VAR pal : PALETTE)
  326.  
  327. Remarks        Palette files created by WGT or popular graphics programs may
  328.                be loaded into the variable specified by PAL. Changes are not
  329.                made to the currently displayed palette. A call to 
  330.                Set_Palette_Block is required to do so. A good example of
  331.                compatibility would be the AutoDesk Animator. It's .COL files
  332.                are of this type. Many commercial games use these files as
  333.                well.
  334.  
  335. See also       Save_Palette, Set_Palette_Block, _SetRGBPalette
  336.  
  337.  
  338.  
  339.  
  340. LoadPCX procedure
  341. ------------------------------------------------------------------------------
  342. Function       Loads a PCX file (320*200*256 only) onto the current graphics
  343.                page.
  344.  
  345. Declaration    LoadPCX(filename : STRING)
  346.  
  347. Remarks        Currently very limited flexibility. Palette files must be 
  348.                loaded separately using Load_Palette. Improved capabilities
  349.                should be available by the time you read this.
  350.  
  351.  
  352.  
  353.  
  354. LoadSprites procedure
  355. ------------------------------------------------------------------------------
  356. Function       Loads a sprite file created by WGT Sprite Creator.
  357.  
  358. Declaration    LoadSprites(filename : STRING; VAR p : palette;
  359.                            VAR block : sprites)
  360.  
  361. Remarks        This loads a sprite file created by the WGT Sprite Creator
  362.                into a palette variable and a variable of type SPRITES.
  363.                The palette is merely loaded into P, not set. The sprite
  364.                data is stored as separate blocks, referenced by the variable
  365.                BLOCK. The type SPRITES is defined as follows:
  366.  
  367.                TYPE sprites = ARRAY [1..100] OF POINTER
  368.  
  369.                The sprite may be displayed by using PUT_BLOCK. For example,
  370.                to show sprite number 54, use
  371.                     PUT_BLOCK(0,0,block[54],normalput);
  372.                If a pointer is set to NIL then there is no sprite in that
  373.                location (ex. BLOCK[54]=NIL)
  374.  
  375. See Also       FreeSprites, Put_Block
  376.  
  377.  
  378.  
  379.  
  380. Mouse procedure
  381. ------------------------------------------------------------------------------
  382. Function       Returns the current button pressed, as well as X and Y
  383.                coordinates.
  384.  
  385. Declaration    Mouse(VAR x,y,button : INTEGER)
  386.  
  387. Remarks        Buttons are commonly returned as 1 for left, 2 for right,
  388.                and 4 for the middle button of a 3 button mouse. 0 is returned
  389.                if none are pressed.
  390.  
  391. See also       Mouse_Init, Mouse_Range, Mouse_On, Mouse_Off, Mouse_Cursor
  392.  
  393.  
  394.  
  395.  
  396. Mouse_Cursor procedure
  397. ------------------------------------------------------------------------------
  398. Function       Sets the bitmap and hotspot of the mouse cursor.
  399.  
  400. Declaration    Mouse_Cursor(rowhot,colhot : INTEGER; VAR bitmap : MOUSEMAP)
  401.  
  402. Remarks        This procedure sets the cursor hotspot as defined by the
  403.                variables ROWHOT and COLHOT. Each are in the range (0..15).
  404.                The actual bitmap information is stored in an array of
  405.                variable type MOUSEMAP. It is defined as follows:
  406.  
  407.                TYPE mousemap = ARRAY [0..31] OF WORD;
  408.  
  409.                The first 16 words are used to set the cursor shape, while the
  410.                last 16 words set the mask. Several shareware programs are
  411.                available to create the data required for these cursors if
  412.                you are unfamiliar with bit operations.
  413.  
  414.  
  415.  
  416.  
  417. Mouse_Init procedure
  418. ------------------------------------------------------------------------------
  419. Function       Initializes the mouse and return # of buttons if installed.
  420.  
  421. Declaration    Mouse_Init(VAR installed : BOOLEAN; VAR buttons : INTEGER)
  422.  
  423. Remarks        Two variables are passed to this function. The first one will
  424.                return TRUE if a mouse is installed. The second will return
  425.                the # of buttons on the mouse if one is present.
  426.  
  427. See also       Mouse_Range, Mouse_On, Mouse_Off, Mouse, Mouse_Cursor
  428.  
  429.  
  430.  
  431.  
  432. Mouse_Off procedure
  433. ------------------------------------------------------------------------------
  434. Function       Turns off display of the mouse cursor.
  435.  
  436. Declaration    Mouse_Off
  437.  
  438. Remarks        See Mouse_On.
  439.  
  440. See also       Mouse_Init, Mouse_Range, Mouse_On, Mouse, Mouse_Cursor
  441.  
  442.  
  443.  
  444.  
  445. Mouse_On procedure
  446. ------------------------------------------------------------------------------
  447. Function       Displays the mouse cursor.
  448.  
  449. Declaration    Mouse_On
  450.  
  451. Remarks        If the mouse is displayed, it may affect some graphics output
  452.                procedures. Turn it off if it causes problems.
  453.  
  454. See also       Mouse_Init, Mouse_Range, Mouse_Off, Mouse, Mouse_Cursor
  455.  
  456.  
  457.  
  458.  
  459. Mouse_Range procedure
  460. ------------------------------------------------------------------------------
  461. Function       Sets the area to confine the mouse cursor to.
  462.  
  463. Declaration    Mouse_Range(minx,miny,maxx,maxy : INTEGER)
  464.  
  465. Remarks        The cursor will be restricted movement within the specified
  466.                region after this routine is called.
  467.  
  468. See also       Mouse_Init, Mouse_On, Mouse_Off, Mouse, Mouse_Cursor
  469.  
  470.  
  471.  
  472.  
  473. Mouse_SetXY procedure
  474. ------------------------------------------------------------------------------
  475. Function       Positions the mouse cursor.
  476.  
  477. Declaration    Mouse_SetXY(x,y : INTEGER)
  478.  
  479. Remarks        Places the mouse cursor at location (X,Y).
  480.  
  481. See Also       Mouse_Init, Mouse_On, Mouse_Off, Mouse_Cursor, Mouse,
  482.                Mouse_Range
  483.  
  484.  
  485.  
  486.  
  487. New_Block procedure
  488. ------------------------------------------------------------------------------
  489. Function       Stores a section of the screen in memory at a location pointed
  490.                to by a pointer variable.
  491.  
  492. Declaration    New_Block(x1,y1,x2,y2 : INTEGER; VAR blockname : POINTER)
  493.  
  494. Remarks        The pointer must be set to NIL before this routine is called.
  495.                Dynamic memory is used to automatically calculate the size of
  496.                the data, and to store it in a format compatible with BGI's
  497.                GETIMAGE. This procedure replaces the need for the combination
  498.                of IMAGESIZE, GETMEM, and GETIMAGE used in the BGI (although
  499.                each of WGT's block commands may be used interchangeably with
  500.                the BGI versions). Simply set a pointer to NIL and call this
  501.                routine.
  502.  
  503. See also       Block_Width, Block_Height, Flip_Block, Put_Block, Resize_Block,
  504.                Free_Block, Load_Block, Save_Block, LoadPAK, SavePAK
  505.  
  506.  
  507.  
  508.  
  509. _OutTextXY procedure
  510. ------------------------------------------------------------------------------
  511. Function       Outputs a string of text on the graphics page at (x,y).
  512.  
  513. Declaration    _OutTextXY(x,y : INTEGER; s : STRING)
  514.  
  515. Remarks        Same as BGI version except it works on any graphics page.
  516.                X/Y coordinate system may be 40*25 or 320*200 (see the
  517.                TextGrid procedure).
  518.  
  519. See also       _TextColor, _TextBackground, TextGrid, TextTransparent,
  520.                TextCursor, TextInput
  521.  
  522.  
  523.  
  524.  
  525. Patches procedure
  526. ------------------------------------------------------------------------------
  527. Function       Dissolves a screen of memory onto the visual screen.
  528.  
  529. Declaration    Patches(mode : INTEGER; VAR source : POINTER; speed : WORD)
  530.  
  531. Remarks        The screen described by SOURCE is dissovled onto the visual
  532.                screen using small blocks (copied randomly). The resolution
  533.                of these blocks varies with the number specified by MODE.
  534.                The higher the mode, the more blocks are required to fill
  535.                the screen. The screen will be divided into sections of 2*2
  536.                to 80*50. The MODE must be in the range (0..7). The speed is
  537.                a DELAY command after each block is copied.
  538.  
  539.  
  540.  
  541.  
  542. Put_Block procedure
  543. ------------------------------------------------------------------------------
  544. Function       Plots a previously stored image on the current graphics page.
  545.  
  546. Declaration    Put_Block(x,y : INTEGER; VAR blockname : POINTER;
  547.                          method : BLOCKMODE)
  548.  
  549. Remarks        This is similar to the BGI PUTIMAGE. It displays an image
  550.                starting from the upper left corner at (x,y). Two modes are
  551.                supported for the method. They are:
  552.  
  553.                TYPE blockmode = (NormalPut, XRayPut)
  554.  
  555.                The XRayPut uses the current transluscent color as a sort of
  556.                "see-through" color. Any occurence of this color is not
  557.                drawn on the screen.
  558.  
  559. See also       Set_Transluscent, Get_Transluscent, New_Block
  560.  
  561.  
  562.  
  563.  
  564. _PutPixel procedure
  565. -------------------------------------------------------------------------------
  566. Function       Plots a pixel at X,Y. Operates on current graphics page.
  567.  
  568. Declaration    _Putpixel(x,y : INTEGER; pixel : BYTE)
  569.  
  570. Remarks        Plots a point in the color defined by Pixel at (x,y).
  571.           
  572. See also       _GetPixel
  573.  
  574.  
  575.  
  576.  
  577. _Rectangle procedure
  578. ------------------------------------------------------------------------------
  579. Function       Draws a rectangle using the current color and graphics page.
  580.  
  581. Declaration    _Rectangle(x1,y1,x2,y2 : INTEGER)
  582.  
  583. Remarks        (x1,y1) define the upper left corner of the rectangle, and
  584.                (x2,y2) define the lower right. Faster than BGI equivalent.
  585.  
  586. See also       _SetColor, _Bar
  587.  
  588.  
  589.  
  590.  
  591. RegionFill procedure
  592. ------------------------------------------------------------------------------
  593. Function       Fills an area of the screen bounded by any color other than
  594.                that located at (x,y).
  595.  
  596. Declaration    RegionFill(x,y : INTEGER)
  597.  
  598. Remarks        Much more useful than the BGI FloodFill routine. It allows
  599.                multiple colors to be used as the border color. It also
  600.                utilizes dynamic memory allocation to provide its own
  601.                'floating stack'. This means that it will fill as much of the
  602.                screen as it can using available memory, and then it will
  603.                release the memory. If the full area is not filled, try using
  604.                the compiler directive {$M 65520,16384,655360} to use all
  605.                possible memory.
  606.  
  607. See also       _SetColor
  608.  
  609.  
  610.  
  611.  
  612. Remove_Screen procedure
  613. ------------------------------------------------------------------------------
  614. Function       Releases the memory used by a graphics page.
  615.  
  616. Declaration    Remove_Screen(VAR screenname : SCREENPTR)
  617.  
  618. Remarks        Used to free the memory reserved by a Init_Screen command.
  619.  
  620. See also       Init_Screen
  621.  
  622.  
  623.  
  624.  
  625. Resize_Block procedure
  626. ------------------------------------------------------------------------------
  627. Function       Draws a previously stored image on the screen to fit within a
  628.                given boundary.
  629.  
  630. Declaration    Resize_Block(x1,y1,x2,y1 : INTEGER; blockname : POINTER)
  631.  
  632. Remarks        A very fast shrink/expand routine for blocks. It will redraw
  633.                an image to fit perfectly within the area defined by
  634.                (x1,y1,x2,y2). In this manner, entire screens can be shrunk
  635.                down as icons, or small images can "explode". Image in memory
  636.                is not affected.
  637.  
  638.  
  639.  
  640.  
  641. Save_Block procedure
  642. ------------------------------------------------------------------------------
  643. Function       Saves a previously stored image to a file on disk.
  644.  
  645. Declaration    Save_Block(filename : STRING; VAR blockname : POINTER)
  646.  
  647. Remarks        A file is created which holds the data stored at the pointer
  648.                given by BLOCKNAME. This allows your programs to load in
  649.                images for use later.
  650.  
  651. See also       Load_Block, New_Block, Free_Block
  652.  
  653.  
  654.  
  655.  
  656. SavePAK procedure
  657. ------------------------------------------------------------------------------
  658. Function       Saves a previously stored image to disk in a compressed
  659.                format.
  660.  
  661. Declaration    SavePAK(filename : STRING; blockname : POINTER)
  662.  
  663. Remarks        This command saves the image referred to by BLOCKNAME to a
  664.                disk file. The image is compressed by an algorithm which is
  665.                dependent on the image's complexity. The more simplistic the
  666.                image, the better the compression.
  667.  
  668. See also       LoadPAK
  669.  
  670.  
  671.  
  672.  
  673. Save_Palette procedure
  674. ------------------------------------------------------------------------------
  675. Function       Save a palette variable's contents to a disk file.
  676.  
  677. Declaration    Save_Palette(filename : STRING; VAR pal : PALETTE);
  678.  
  679. Remarks        Creates a 768 byte palette file to disk from a variable
  680.                specified by PAL. This is useful for storing different
  681.                palettes for games and their various screens.
  682.  
  683. See also       Load_Palette, Set_Palette_Block, _SetRGBPalette
  684.  
  685.  
  686.  
  687.  
  688. Scroll procedure
  689. ------------------------------------------------------------------------------
  690. Function       Scrolls a section of the screen in one of 4 directions
  691.  
  692. Declaration    Scroll(x1,y1,x2,y2 : INTEGER; dir : DIRECTIONS; amt : INTEGER)
  693.  
  694. Remarks        Region defined by (x1,y1,x2,y2) is scrolled up,down,left or
  695.                right one pixel at a time. This is repeated for the number
  696.                of times indicated by AMT. This procedure is not very fast
  697.                for large screen sections. The last column or row is not 
  698.                moved at all, so try not to move borders. For example, if
  699.                you move an area down 6, the top row is smeared if it is not
  700.                the background color.
  701.  
  702.                TYPE Directions = (up, down, left, right)
  703.  
  704.  
  705.  
  706.  
  707. _SetColor procedure
  708. ------------------------------------------------------------------------------
  709. Function       Sets the current drawing color using the palette.
  710.  
  711. Declaration    _SetColor(color : BYTE)
  712.  
  713. Remarks        Color may be in the range (0..255). This sets both the WGT and
  714.                the BGI drawing colors, so you never need to use the BGI
  715.                version again. 
  716.  
  717. See also       Set_Palette_Block, _SetRGBPalette, Load_Palette, Save_Palette
  718.  
  719.  
  720.  
  721.  
  722. Set_Palette_Block procedure
  723. ------------------------------------------------------------------------------
  724. Function       Sets a group of colors from a specified palette variable.
  725.  
  726. Declaration    Set_Palette_Block(start,finish : WORD; VAR block : PALETTE)
  727.  
  728. Remarks        Colors from Start to Finish are set using the values stored
  729.                in the Palette variable. The variable type PALETTE is specific
  730.                to WGT and may not be used elsewhere. It is defined as
  731.                follows:
  732.  
  733.                TYPE ColorType = RECORD
  734.                     R : BYTE;
  735.                     G : BYTE;
  736.                     B : BYTE;
  737.                     END;
  738.                Palette = array [0..255] of ColorType;
  739.  
  740.                where R,G, and B are in the range (0..63) giving a total of
  741.                256000 color combinations possible. The array may be accessed
  742.                individually from (0..255).
  743.  
  744. See also       _SetRGBPalette, Load_Palette, Save_Palette, _SetColor
  745.  
  746.  
  747.  
  748.  
  749. _SetRGBPalette procedure
  750. ------------------------------------------------------------------------------
  751. Function       Sets the individual RGB registers of a color number in a
  752.                palette variable.
  753.  
  754. Declaration    _SetRGBPalette(color,red,green,blue : BYTE; VAR pal : PALETTE)
  755.  
  756. Remarks        This command is different from the BGI version in that it does
  757.                not actually set the color, it only changes the palette
  758.                variable. A call to Set_Palette_Block is required to make
  759.                changes visible.
  760.  
  761. See also       Set_Palette_Block, _SetColor
  762.  
  763.  
  764.  
  765.  
  766. Set_Transluscent procedure
  767. ------------------------------------------------------------------------------
  768. Function       Sets the transluscent color used by Put_Block's XRayPut mode.
  769.  
  770. Declaration    Set_Transluscent(color : BYTE)
  771.  
  772. Remarks        The color set by this function will not be drawn when using
  773.                Put_Block with XRayPut.
  774.  
  775. See also       Put_Block, Get_Transluscent
  776.  
  777.  
  778.  
  779.  
  780. _SetViewPort procedure
  781. ------------------------------------------------------------------------------
  782. Function       Sets the current clipping area for all graphics pages.
  783.  
  784. Declaration    _SetViewPort(x1,y1,x2,y2 : INTEGER)
  785.  
  786. Remarks        (x1,y1) define the upper left corner of the clipping area,
  787.                and (x2,y2) define the lower right. Designated WGT drawing
  788.                commands will only draw within this boundary. A call to BGI's
  789.                SetViewPort is not required because this procedure also sets
  790.                the BGI clipping. Set coordinates to (0,0,319,199) to disable
  791.                clipping.
  792.  
  793. Restrictions   See EXTRA.DOC for information concerning which commands are
  794.                supported by this function.
  795.  
  796.  
  797.  
  798.  
  799. _TextBackGround procedure
  800. ------------------------------------------------------------------------------
  801. Function       Sets the background text color.
  802.  
  803. Declaration    _TextBackground(color : BYTE)
  804.  
  805. Remarks        Color is in the range (0..255). Background may be turned off
  806.                for output by using TextTransparent.
  807.  
  808. See also       _OutTextXY, _TextColor, TextTransparent, TextInput
  809.  
  810.  
  811.  
  812.  
  813. _TextColor procedure
  814. ------------------------------------------------------------------------------
  815. Function       Selects the foreground character color.
  816.  
  817. Declaration    _TextColor(color : BYTE)
  818.  
  819. Remarks        Color is in the range (0..255). Foreground may be turned off
  820.                during output by setting TextTransparent.
  821.  
  822. See also       _OutTextXY, _TextBackGround, TextTransparent, TextInput
  823.  
  824.  
  825.  
  826.  
  827. TextCursor procedure
  828. ------------------------------------------------------------------------------
  829. Function       Sets the shape of the text cursor.
  830.  
  831. Declaration    TextCursor(x,y,x2,y2 : BYTE)
  832.  
  833. Remarks        X and Y coordinates are in the range (0..7). The cursor is not
  834.                the hardware text cursor, but rather a software simulation.
  835.                It is an 8*8 pixel box which flashes during text input. To
  836.                make a regular text cursor shape, use (0,7,7,7). A solid box
  837.                results from (0,0,7,7). Vertical lines (?) may also be created.
  838.  
  839. See Also       TextInput
  840.  
  841.  
  842.  
  843.  
  844. TextGrid procedure
  845. ------------------------------------------------------------------------------
  846. Function       Switches the text addressing system from 320*200 to 40*25.
  847.  
  848. Declaration    TextGrid(state : BOOLEAN)
  849.  
  850. Remarks        Text may be output in regular graphics coordinates (320*200) or
  851.                a text mode system of 40*25. If STATE is set to TRUE, all input
  852.                and output values for WGT text functions are expected to be
  853.                in the 40*25 range. Characters will be 'snapped' to the grid as
  854.                if it were a text mode. FALSE will use regular graphics system
  855.                coordinates.
  856.  
  857. See Also       _OutTextXY, TextInput
  858.  
  859.  
  860.  
  861.  
  862. TextInput procedure
  863. ------------------------------------------------------------------------------
  864. Function       Reads in a string of text from the keyboard and displays
  865.                both the text and a simulated cursor on the graphics page.
  866.  
  867. Declaration    TextInput(x,y : INTEGER; format : STRING; VAR result : STRING)
  868.  
  869. Remarks        This simulates a READLN on the graphics screen. This is a
  870.                formatted input procedure. The desired format is passed as
  871.                a string. It is defined as follows:
  872.  
  873.                Character    Function
  874.                   '*'       Allows entry of any ASCII character.
  875.                   '#'       Allows entry of numbers from 0-9.
  876.                   '.'       A hard-coded decimal point not moveable by user.
  877.                   ' '       Output skips over this space in the string.
  878.  
  879.                For example, a format string of '**** ##.##' will accept four
  880.                characters of any type, then skip a spot, accept two numbers,
  881.                display a period, and then accept another two numbers.
  882.  
  883. Restrictions   INSERT,DELETE,HOME, and the arrow keys are not functional,
  884.                backspace is non-destructive. (Future versions will differ).
  885.  
  886. See Also       _TextColor, _TextBackGround, TextGrid, TextTransparent
  887.  
  888.  
  889.  
  890.  
  891. TextTransparent procedure
  892. ------------------------------------------------------------------------------
  893. Function       Sets text output to supress display of foreground or
  894.                background.
  895.  
  896. Declaration    TextTransparent(noshow : HIDETYPE);
  897.  
  898. Remarks        This will turn off the display of either the foreground or the
  899.                background, or set it to show both. The type HIDETYPE is
  900.                defined as follows:
  901.  
  902.                TYPE hidetype = (mask, letter, none)
  903.  
  904.                If NOSHOW is set to MASK, the background is turned off. LETTER
  905.                turns off the foreground. NONE is used when you want to display
  906.                both the foreground and background.
  907.